﻿
new Vue({
    el: '#app',
    delimiters:['[[', ']]'],

    data: {
        tag_id: {{ tag.tag_id }},
        tag_name: '{{ tag.tag_name }}',
        tag_heat_factor: '{{ tag.heat_factor }}',
        tag_orderno: '{{ tag.orderno }}',
    },

    methods: {
        saveRoomTagInfo() {
            let url = "{% url 'gma:api_edit_room_tag' %}";
            let data = {
                'tag_id' : this.tag_id,
                'tag_name' : this.tag_name,
                'tag_heat_factor' : this.tag_heat_factor,
                'tag_orderno' : this.tag_orderno,
            };
            new my_ajax(url, data, '', '', () => {
                show_toast('修改成功');
                redirect();
            });
        },

        cancel() {
            window.history.back();
        },
    },

    mounted() {
    },
});
